<?php
/************************************/
/*   DOUI框架，想DO就DO，想到就能做到   */
/************************************/

if(PHP_VERSION < 5.4){
	echo '<div style="font:160px/1.5 Arial;">:(</div>';
	echo '<fieldset><legend>温馨提示</legend>程序要求php版本至少为5.4.x，请升级php</fieldset>';
	exit;
}

define('ROOT', __DIR__ . '/');
define('APPS', ROOT.'apps/');
define('CORE', ROOT.'core/');

require_once CORE . 'init.php';

$_G['cache'] = new Do_Cache;

//缓存客户端信息
$client = new Do_Browser;
$_G['client'] = [
	'os' => $client->get_os(),
	'browser' => $client->browser(),
	'is_pad' => $client->is_pad(),
	'is_phone' => $client->is_phone(),
	'is_mobile' => $client->is_mobile()
];

D::run();

$cont = ob_get_clean();
if (function_exists('ob_gzhandler')){
    ob_start('ob_gzhandler');
}else{
    ob_start();
}
echo $cont;
ob_end_flush();

exit;

